package com.company.project.mapper;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.company.project.entity.SysDept;
import com.company.project.entity.SysUser;
import com.company.project.entity.TKhtjEntity;
import com.company.project.entity.TWdkhEntity;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.company.project.vo.req.HomeTJReqVO;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

/**
 * 
 * 
 * @author wenbin
 * @email *****@mail.com
 * @date 2023-11-09 18:03:05
 */
public interface TWdkhMapper extends BaseMapper<TWdkhEntity> {

    void updateUsername(@Param("ids") List<String> ids, @Param("username") String username);

    void rlgh(@Param("ids") List<String> ids);

    List<String> selectUsername(@Param("deptNo") String deptNo,@Param("sysUser") SysUser sysUser);

    List<String> selectKuly(@Param("deptNo") String deptNo);

    List<String> selectHkjb(@Param("deptNo") String deptNo);

    List<String> selectSsxs(@Param("deptNo") String deptNo,@Param("sysUser") SysUser sysUser);

    void updateSsxs(@Param("ids") List<String> ids,@Param("ssxs") String ssxs);

    Integer selectCountByUser(String username);

    IPage<TWdkhEntity> pageKhcc(@Param("page")Page page,@Param("twdkh") TWdkhEntity tWdkh);

    List<String> selectLrgh();

    List<String> selectSsxsAll();

    String selectKhsl(@Param("user")String user);

    String selectYxdsl(@Param("user")String user);

    void insertTKhtj(@Param("khsl")String khsl,@Param("yxdsl") String yxdsl,@Param("time") String time, @Param("type")String type,@Param("user") String user);

    List<TKhtjEntity> getWdkhTJ(@Param("user")SysUser user, @Param("vo") HomeTJReqVO vo,@Param("dept") SysDept dept);

    Integer getWdkhCount(@Param("type")String type,@Param("dept") String dept,@Param("user") String user);

    Integer getWdkhYxCount(@Param("type")String type,@Param("dept") String dept,@Param("user") String user);

    List<Map<String,String>> getKhlbByUser(@Param("user")String user,@Param("dept") String dept);
}
